package com.hcs.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.util.Date;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;

/**
 * <p>
 * 
 * </p>
 *
 * @author hcs
 * @since 2025-01-12 09:26
 */
@Getter
@Setter
@TableName("role_permission")
@Schema(name = "role_permission", description = "角色-权限关联表")
public class RolePermission {

    // 关联 `role` 表
    @Schema(description = " 关联 `role` 表")
    @TableId(value = "role_id", type = IdType.AUTO)
    private Long roleId;

    //关联 `permission` 表
    @Schema(description = "关联 `permission` 表")
    @TableField(value = "permission_id")
    private Long permissionId;

    // 创建时间
    @Schema(description = "创建时间")
    @TableField("created_at")
    private Date createdAt;
}
